class CreatePeople < ActiveRecord::Migration
  def change
    create_table :people do |t|
      t.integer  :church_id,                  :null => false
      t.string   :first_name,                 :null => false
      t.string   :last_name,                  :null => false
      t.string   :address,                    :null => false
      t.string   :city,                       :null => false
      t.string   :state,    :limit => 2,      :null => false
      t.string   :zip_code, :limit => 10,     :null => false
      t.string   :phone
      t.string   :email
      t.text     :note
      t.integer  :status_id,                  :null => false
      t.boolean  :enabled,  :default => true, :null => false

      t.timestamps
    end
    add_index :people, :church_id,   :unique => false
    add_index :people, :first_name,  :unique => false
    add_index :people, :last_name,   :unique => false
    add_index :people, :status_id,   :unique => false
    add_index :people, :enabled,     :unique => false
  end
end
